﻿using SqlSugar;
using System.ComponentModel.DataAnnotations.Schema;

namespace LDM.Sys.ServiceAPI.Model.DBModel
{
    /// <summary>
    /// 用户主表
    /// </summary>
    [SugarTable("account", TableDescription = "用户主表")]
    public class Account
    {
        /// <summary>
        /// 主键
        /// </summary>
        [SugarColumn(IsIdentity = true, IsPrimaryKey = true)]
        public int Id { get; set; }

        /// <summary>
        /// 用户来源类型 1后台端 2微信端 3商户端
        /// </summary>
        public int UserSourceType { get; set; }

        /// <summary>
        /// 关联用户ID
        /// </summary>
        public int RelUserId { get; set; }

        /// <summary>
        /// 创建时间
        /// </summary>
        public DateTime CreateTime { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public DateTime UpdateTime { get; set; }

    }
    /// <summary>
    /// 后台管理用户信息
    /// </summary>
    [SugarTable("sys_account", TableDescription = "后台管理用户信息")]
    public class SysAccount
    {
        /// <summary>
        /// 
        /// </summary>
        [SugarColumn(IsIdentity = true, IsPrimaryKey = true)]
        public int Id { get; set; }

        /// <summary>
        /// 昵称
        /// </summary>
        public string NickName { get; set; }

        /// <summary>
        /// 英文账号(主要账号信息，不能重名)
        /// </summary>
        public string EnglishAccount { get; set; }

        /// <summary>
        /// 用户类型
        /// </summary>
        public int UserType { get; set; }

        /// <summary>
        /// 密码
        /// </summary>
        public string Password { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public DateTime CreateTime { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public DateTime UpdateTime { get; set; }

    }

    /// <summary>
    /// 微信用户信息
    /// </summary>
    [SugarTable("wx_account", TableDescription = "微信用户信息")]
    public class WxAccount
    {
        /// <summary>
        /// 
        /// </summary>
        [SugarColumn(IsIdentity = true, IsPrimaryKey = true)]
        public int Id { get; set; }

        /// <summary>
        /// OpenId
        /// </summary>
        public string OpenId { get; set; }

        /// <summary>
        /// 昵称
        /// </summary>
        public string NickName { get; set; }

        /// <summary>
        /// 用户类型
        /// </summary>
        public int UserType { get; set; }

        /// <summary>
        /// 手机号
        /// </summary>
        public string Phone { get; set; }

        /// <summary>
        /// 状态
        /// </summary>
        public bool StatusFlag { get; set; }

        /// <summary>
        /// 用户头像
        /// </summary>
        public string UserFaceImg { get; set; }

        /// <summary>
        /// 邮箱
        /// </summary>
        public string Email { get; set; }

        /// <summary>
        /// 密码
        /// </summary>
        public string Password { get; set; }

        /// <summary>
        /// 性别
        /// </summary>
        public int Gender { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public DateTime CreateTime { get; set; }

        /// <summary>
        /// 
        /// </summary>
        public DateTime UpdateTime { get; set; }

    }


    /////<summary>
    ///// 用户信息
    /////</summary>
    //[SugarTable("Sys_UserInfo", TableDescription = "用户信息")]
    //public class SysUserInfo
    //{
    //    /// <summary>
    //    /// Desc:主键
    //    /// Default:
    //    /// Nullable:False
    //    /// </summary>    

    //    [SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
    //    public int Id { get; set; }

    //    /// <summary>
    //    /// 微信登录唯一id
    //    /// </summary>
    //    public string OpenId { get; set; }

    //    /// <summary>
    //    /// Desc:
    //    /// Default:
    //    /// Nullable:False
    //    /// </summary>           
    //    public string NickName { get; set; }

    //    /// <summary>
    //    /// Desc:
    //    /// Default:
    //    /// Nullable:False
    //    /// <see cref="Enum.UserTypeEnum"/>
    //    /// </summary>           
    //    public int UserType { get; set; }

    //    /// <summary>
    //    /// Desc:
    //    /// Default:
    //    /// Nullable:False
    //    /// </summary>           
    //    public string Phone { get; set; }

    //    /// <summary>
    //    /// Desc:状态值：0删除 1有效
    //    /// Default:
    //    /// Nullable:False
    //    /// </summary>           
    //    public bool StatusFlag { get; set; }

    //    /// <summary>
    //    /// Desc:
    //    /// Default:
    //    /// Nullable:True
    //    /// </summary>           
    //    public string UserFaceImg { get; set; }

    //    /// <summary>
    //    /// Desc:
    //    /// Default:
    //    /// Nullable:True
    //    /// </summary>           
    //    public string Email { get; set; }

    //    /// <summary>
    //    /// Desc:
    //    /// Default:
    //    /// Nullable:True
    //    /// </summary>           
    //    public string Password { get; set; }

    //    /// <summary>
    //    /// Desc:性别
    //    /// Default:
    //    /// Nullable:False
    //    /// </summary>           
    //    public int Gender { get; set; }

    //    /// <summary>
    //    /// Desc:
    //    /// Default:
    //    /// Nullable:True
    //    /// </summary>           
    //    public DateTime CreateTime { get; set; }

    //    /// <summary>
    //    /// Desc:
    //    /// Default:
    //    /// Nullable:True
    //    /// </summary>           
    //    public DateTime UpdateTime { get; set; }
    //}
}
